<template>
  <span >{{item.id}}: {{result()}}</span>
</template>

<script>
export default {
  data() {
    return {

    }
  },
  props: ['item'],
  methods: {
    result() {
      if (this.item.isComplete === 0) { 
        return '未完成'
      } else if (this.item.isComplete === 1) { 
        return '回答正确'
      } else { 
        return '回答错误'
      }
    }

  }
};
</script>

<style scoped>
.right {
  color: green;
}
.error {
  color: red;
}
.undo {
  color: #ccc;
}
</style>